package com.example.demo.entity;

import lombok.Data;
import org.springframework.stereotype.Component;

@Data
@Component
public class ApiResponse{

    private int code;
    private String message;
    private Object data;
    public ApiResponse(){}

    public ApiResponse(int code, String message, Object data) {
        this.code = code;
        this.message = message;
        this.data = data;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }
}
